-- GENERATED SPELL FOR [Cryo-Engineer Sha'heen] --


function spell0_19671(pUnit, Event) --@Arcane Bolt,n/a--
pUnit:FullCastSpellOnTarget(13901,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_19671', 2500, 1)
end

function spell1_19671(pUnit, Event) --@Arcane Explosion,Self--
pUnit:FullCastSpellOnTarget(22938,pUnit)
pUnit:RegisterEvent('Sorts_19671', 1000, 1)
end

function spell2_19671(pUnit, Event) --@Blink,Self--
pUnit:FullCastSpellOnTarget(14514,pUnit)
pUnit:RegisterEvent('Sorts_19671', 1281, 1)
end

function spell3_19671(pUnit, Event) --@Vir\'aani Concentration,Self--
pUnit:FullCastSpellOnTarget(33839,pUnit)
pUnit:RegisterEvent('Sorts_19671', 552, 1)
end

function Sorts_19671(pUnit, Event)
local choix_sorts_19671 = math.random(0, 3)
if choix_sorts_19671 == 0 then
pUnit:RegisterEvent('spell0_19671', 1, 1)
end
if choix_sorts_19671 == 1 then
pUnit:RegisterEvent('spell1_19671', 1, 1)
end
if choix_sorts_19671 == 2 then
pUnit:RegisterEvent('spell2_19671', 1, 1)
end
if choix_sorts_19671 == 3 then
pUnit:RegisterEvent('spell3_19671', 1, 1)
end
end

function mob19671_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_19671', math.random(1500, 3000), 1)
end

function mob19671_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19671_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob19671_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(19671, 1, 'mob19671_Action')
RegisterUnitEvent(19671, 2, 'mob19671_Leave')
RegisterUnitEvent(19671, 3, 'mob19671_Kill')
RegisterUnitEvent(19671, 4, 'mob19671_Die')
